public class Edge {

	public Vertex dest;
	public double cost;
	public boolean isVisited;

	public Edge(Vertex dest, double cost) {
		this.dest = dest;
		this.cost = cost;
	}

	public Vertex getDestination() {
		return dest;
	}

	public void setVisited(boolean visited) {
		isVisited = visited;
	}

	public boolean isVisited() {
		return isVisited;
	}

	public double getCost() {
		return cost;
	}

	public void setLeastCost(double weight) {
		dest.setLeastCost(weight + getCost());
	}

}
